﻿/**	\file		case_pool.h
 *	\date		(2014-09-16 23:02:27)/(2014-11-29 15:34:15)
 *-----------------------------------------------------------------------------
 *	\version	1.0.0.1
 *	\author		Nick Shallery	(nicknide@gmail.com)
 *	\copyright	YOU HAVE ALL LEFT WITH THIS CODE WHILE YOU KEEP COMMENT IN EVERY COPY.
 *-----------------------------------------------------------------------------
**/

#if			!defined(__LOLIX__TRIAL__CASE_POOL__NICK__K_IN_G__)
#define		__LOLIX__TRIAL__CASE_POOL__NICK__K_IN_G__


#if			!defined(__LOLIX__LOLIX_TYPE__K_IN_G__)
	#include	"../lolix/lolix_type.h"
#endif	//	!defined(__LOLIX__LOLIX_TYPE__K_IN_G__)


namespace lxtrial
{
	class case_ctrl;
	class icase;
	/**
	 * \brief	用例所注册所需的容器.
	**/
	class LOLIX_NO_VTABLE case_pool
		: public lolix::itf
	{
		LOLIX_DECLARE_ITF(lxtrial::case_pool, lolix::itf, (0xe26068aa, 0xdfde4699, 0x9833f6f7, 0xe28f5241));

		/**
		 * \brief	添加一个新的用例.
		 *
		 * \param [in]	in_case		需要添加的用例.
		 * \return	返回是否添加成功.
		**/
		LOLIX_INTERFACE(add_case, lolix::LOLIX_RETNV, (icase* in_case));

		/**
		 * \brief	删除一个已经添加的用例.
		 *
		 * \param [in]	in_case		需要删除的用例.
		 * \return	返回是否删除成功.
		**/
		LOLIX_INTERFACE(rmv_case, lolix::LOLIX_RETNV, (icase const* in_case));

		/**
		 * \brief	得到一个控制对象.
		 *
		 * \param	[out] out_ptr		输出的对象.
		 * \return	如果成功，则 LOLIX_IS_ERROR 返回 false.
		**/
		LOLIX_INTERFACE(query_control, lolix::LOLIX_RETNV, (case_ctrl** out_ptr));
	};
}

#endif	//	!defined(__LOLIX__TRIAL__CASE_POOL__NICK__K_IN_G__)
